<?php if (!defined('THINK_PATH')) exit();?>﻿<html>
	<head>
	<script type="text/javascript" src="__JS__/menu.js"></script>
	<script type="text/javascript" src="__JS__/leftmenubar.js"></script>
	<link rel="stylesheet" type="text/css" href="__CSS__/header.css" />
	<link rel="stylesheet" type="text/css" href="__CSS__/footer.css" />
	<link  rel="stylesheet" href="__CSS__/collegedetail_style.css" type="text/css"> 
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<script type="text/javascript" src="__JS__/jshelper.js"></script>
		<title>信息管理</title>
			<script type="text/JavaScript">
				function infoedit(no){
					window.location.href="__URL__/infoedit/no/"+no;
				}
				
				function infodelete(no){
					if (confirm("你确定要删除吗")==true)
						postwith('__URL__/infodelete',{no:no});
				}
					window.onload=show;
			</script>
	</head>
	<body>
	<!-- layout::Auth:header::0 -->
	<div  class="nowposition">
		当前位置：
			<a href='__APP__/index/index' class="nowpositionhref">主页</a>>
			<a href='__URL__/index' class="nowpositionhref">后台管理</a>>
			<a href=""class="nowpositionhref">用户管理</a>
	</div>
	<!-- layout::Auth:leftmenu::0 -->
	<div class="infodetail">
		<div align="left" style="width:800px; position:relative; left:210px;" >
				<a href="__URL__/infoadd" style="color:#3300CC; text-decoration:none">添加用户</a>
				<a href="__URL__/infoimport" style="color:#3300CC; text-decoration:none">批量添加用户</a>
		</div>
		<div style=" width:850px; position:relative; left:210px;" align="left">
          <form method="get" action="__URL__/infodetail" >
            工号/学号：
      <input type="text" name="no">
            姓名:
            <input type="text" name="name">
            所在院系：
            <select name="dname">
              <option value =></option>
              <?php if(is_array($deplist)): $i = 0; $__LIST__ = $deplist;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): ++$i;$mod = ($i % 2 )?><option value =	<?php echo ($vo["name"]); ?>><?php echo ($vo["name"]); ?></option><?php endforeach; endif; else: echo "" ;endif; ?>
            </select>
            <input name="submit" type="submit" value="查询">
          </form>
	  </div>
	  <div  style="width:68%; position:relative; left:210px;">
		<table width="100%" h border="0" align="center" cellpadding="0px" cellspacing="0px">
				<thead style="background-color:f0f0f0;">
					<tr style="height:35px;">
						<td>工号</td>
						<td>姓名</td>
						<td>权限</td>
						<td>院系</td>
						<td>操作</td>
					</tr>
				</thead>
				<load href"__PUBLIC__/js/list_show.js">
				<tbody id="tab">
					<?php if(is_array($list)): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): ++$i;$mod = ($i % 2 )?><tr style="height:35px;">
							<td><?php echo ($vo["no"]); ?></td> <!--工号-->
							<td><?php echo ($vo["name"]); ?></td><!--姓名-->
							<td><?php echo ($vo["role"]); ?></td><!--权限-->
							<td><?php echo ($vo["dname"]); ?></td><!--院系-->
							<td>
							<?php if($role == '院系管理员' and $vo["role"] == '校级管理员'): ?>权限不够无法操作
								<?php else: ?>
									<a name="infoedit" onClick="infoedit('<?php echo ($vo["no"]); ?>')" href="#" class="blue">编辑</a>
									<!--<input type="button" name="collegeedit"  onClick="" value="编辑">-->
									<a name="delete_info" onClick="infodelete(<?php echo ($vo["no"]); ?>)" href="#" class="red">删除</a>
									<!--<input name="delete_college" type="reset" onClick="" value="删除">--><?php endif; ?>
							</td>
						</tr><?php endforeach; endif; else: echo "" ;endif; ?>
				</tbody>
	  </table>
	  </div>
		<div class="green-black" style="position:relative; top:15px; left:785px; width:120px; display:inline"><?php echo ($page); ?></div>
	</div>
	</body>
</html>